package com.softtown.modules.organization.dao;

import com.softtown.common.dao.BaseDao;
import com.softtown.modules.organization.entity.CompOrgPosnEntity;
import org.apache.ibatis.annotations.Mapper;

import java.util.List;

/**
 * @version v1.0
 * @ProjectName: softtown-aioffice
 * @ClassName: CompOrgPosnDao
 * @Description: 公司岗位Dao层
 * @Author: fuming
 * @Date: 2019/6/5 10:19
 */
@Mapper
public interface CompOrgPosnDao extends BaseDao<CompOrgPosnEntity> {

    /**
     * 根据公司所属的ID查找出相对应的岗位相关信息
     * @param companyId
     * @return java.util.List<com.softtown.modules.organization.entity.CompOrgPosnEntity>
     * @Author fuming
     * @Date 2020/5/26 15:43
     */
    List<CompOrgPosnEntity> getPosnListByCompId(Long companyId);

    List<CompOrgPosnEntity> getCompExecPosn(Long companyId);

    /**
     * 岗位修改
     * @param compOrgPosnEntity
     * @return boolean
     * @Author fuming
     * @Date 2020/5/26 15:43
     */
    boolean updatePosnInfos(CompOrgPosnEntity compOrgPosnEntity);

    /**
     * 通过id找出相对应的岗位信息
     * @param id
     * @return com.softtown.modules.organization.entity.CompOrgPosnEntity
     * @Author fuming
     * @Date 2020/5/26 15:44
     */
    CompOrgPosnEntity getPosnInfoById(Long id);

    /**
     * 通过id找出相对应的岗位信息
     * @param id
     * @return com.softtown.modules.organization.entity.CompOrgPosnEntity
     * @Author fuming
     * @Date 2020/5/26 15:43
     */
    CompOrgPosnEntity getPositionInfoById(Long id);

    /**
     * 根据公司id找出对应的岗位
     *
     * @param compId
     * @return List<CompOrgPosnEntity>
     * @author Dingyayong
     * @date 2019/9/25 10:57
     */
    List<CompOrgPosnEntity> getFindPosnByCompId(Long compId);
}
